package com.bjdd.jdy.util;

import android.app.Dialog;
import android.content.Context;

import com.bjdd.jdy.R;
import com.bjdd.jdy.view.widget.LoadingDialog;


public class DialogUtil {
	private Context context;

	public DialogUtil(Context context) {
		super();
		this.context = context;
	}

	/**
	 * 获取加载中对话框
	 * @param tip
	 * @param isCanClose
     * @return
     */
	public Dialog getWaitDialog(String tip, Boolean isCanClose) {
		LoadingDialog dialog = new LoadingDialog(context, R.style.dialogBase);
		dialog.setTipText(tip);
		dialog.setCanceledOnTouchOutside(isCanClose);
		dialog.setCancelable(true);
		dialog.show();
		return dialog;
	}

}
